<!-- 
1. 高危信号中，如果上周总数为0时，增长率不用显示百分号 -->
<!DOCTYPE html>
<html>

<head>
<meta charset="UTF-8">
<title>消防周报</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no, viewport-fit=cover">
<meta name="Copyright" content="">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="default">
<meta name="viewport"
	content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<!-- 禁用链接高亮 -->
<meta name="theme-color" content="#2196f3">
<style type="text/css">
.page {
	overflow: hidden;
	width: 100%;
	position: absolute;
	top: 0;
	left: 0;
	height: 100%;
	box-sizing: border-box;
	background-color: #fff;
}

.page-content {
    overflow-x: hidden;
    box-sizing: border-box;
    height: 100%;
    position: relative;
    z-index: 1;
    padding: 70px 15px 30px 15px;
    background:rgba(251,251,251,1);
}
p, ul {
	margin: 0px;
	padding: 0px;
}

.page-weekly .iconfont {
	font-family: "iconfont" !important;
	font-size: 16px;
	font-style: normal;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

.page-weekly .link-page-top {
    position: absolute;
    top: -2px;
    left: 0;
    z-index: 9;
    width: calc(100% - 40px);
    background-color: #fff;
    padding: 10px 20px;
    padding-bottom: 0;
}

.page-weekly .link-page-top .link {
	color: #000;
}

.page-weekly .link-page-top .link img {
	vertical-align: middle;
}

.page-weekly .link-page-title {
    font-size: 24px;
    color: #000000;
    background-color: white;
    font-weight: bold;
    width: 70%;
    display: inline-block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.page-weekly .link-page-top .link-date {
	font-size: 14px;
	font-weight: 400;
	color: rgba(74, 133, 207, 1);
	line-height: 25px;
	margin-right: 50px;
	word-wrap: break-word;
}

.situation-chart, .week-dangerous-leaderboard, .fireHazard-content,
	.control-room-review, .hiddenCheck-content, .keyIssues-content, .fire-passage, .electromobile-upstaire, .gas-cylinder-upstaire {
	background: rgba(255, 255, 255, 1);
	border: 1px solid rgba(225, 225, 225, 0.4);
	box-shadow: 0px 0px 15px 0px rgba(205, 205, 205, 0.2);
	border-radius: 10px;
	padding: 20px 10px;
	margin: 20px 0px;
}

.week-security-situation>.situation-chart{
	height: 210px;
}

.situation-chart div, .keyIssues-chart div, .fireHazard-chart div {
	/*width: 100%;*/
	height: 240px;
}

.hiddenCheck-chart {
	position: relative;
}

.hiddenCheck-chart #hiddenCheckChart {
	height: 240px;
}

.hiddenCheck-content .hiddenCheck-chart-info {
	width: 100%;
	height: 160px;
	text-align: center;
	position: absolute;
	top: 90px;
}

.hiddenCheck-content .hiddenCheck-chart-info div span {
	font-size: 34px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	color: rgba(250, 127, 95, 1);
}

.hiddenCheck-content .hiddenCheck-chart-info div span:last-child {
	font-size: 12px;
}

.hiddenCheck-content .hiddenCheck-chart-info div:last-child {
	font-size: 14px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	color: rgba(153, 153, 153, 1);
}

.week-dangerous-leaderboard .content-top-title {
	margin-bottom: 20px;
}

.content-top-title .title-text {
	font-size: 18px;
	font-family: PingFangSC-Semibold;
	font-weight: bold;
	color: #444444;
	margin-left: 2px;
	line-height: 18px;
}

.content-top-title .title-desc {
	font-size: 14px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	color: rgba(153, 153, 153, 1);
	margin-left: 2px;
}

.dangerous-leaderboard-content ul {
	padding: 0px;
}

.dangerous-leaderboard-content ul li {
	list-style: none;
	position: relative;
	padding: 0px 5px;
	display: flex;
	align-items: center;
	margin-top: 12px;
}

.duty-detail-org ul li, .keyIssues-leaderboard ul li {
	list-style: none;
	position: relative;
}

.duty-detail-org ul li, .keyIssues-leaderboard ul li {
	margin-top: 20px;
	display: flex;
	align-items: center;
}

ul li .item-number {
	/* position: absolute;
	top: 5px; */
}

.dangerous-leaderboard-content ul li .item-number {
	top: 10px;
	left: 0;
}

ul li .item-number .item-num-div {
	width: 23px;
	height: 23px;
	line-height: 23px;
	background: rgba(35, 128, 195, 0.1);
	border-radius: 50%;
	text-align: center;
	font-size: 12px;
	font-family: PingFangSC-Semibold;
	font-weight: 600;
	color: rgba(59, 130, 214, 1);
}

.duty-detail-org ul li .item-content, .keyIssues-leaderboard ul li .item-content
	{
	margin-left: 10px;
	height: 25px;
	line-height: 25px;
	display: flex;
    justify-content: space-between;
    width: 100%;
}

.duty-detail-org ul li .item-content div, .keyIssues-leaderboard ul li .item-content div
	{
	display: inline-block;
	/* margin-top: 4px; */
}

.dangerous-leaderboard-content li .item-desc {
	margin-left: 10px;
	width: 100%;
	margin-top: -4px;
}

.dangerous-leaderboard-content li .item-desc .item-desc-flex {
	display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.dangerous-leaderboard-content li .item-desc .therm.outer-therm{
	margin: 0;
}

.dangerous-leaderboard-content li .item-desc p:first-child {
	font-size: 14px;
	color: #444444;
}

.dangerous-leaderboard-content li .item-desc p {
	font-size: 12px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	line-height: 14px;
	color: rgba(153, 153, 153, 1);
}

.dangerous-leaderboard-content .progressbar {
	height: 10px !important;
	width: 60%;
	margin-top: 5px;
	float: left;
	margin-left: 10px;
	border-radius: 4px;
}

.dangerous-leaderboard-content .progressbar span {
	width: 100%;
	height: 100%;
	position: absolute;
	left: 0;
	top: 0;
	-webkit-transform: translate3d(-100%, 0, 0);
	transform: translate3d(-100%, 0, 0);
	-webkit-transition-duration: 150ms;
	transition-duration: 150ms;
	background: #2196f3;
}

.statistics-quantity {
	display: inline-block;
	width: 100%;
	margin-top: 20px;
}

.statistics-quantity>div {
	width: 100%;
	display: inline-flex;
	justify-content: space-around;
	padding: 20px 0;
    background: rgba(225, 225, 225, 0.2);
}

.statistics-quantity>div>div{
	display: inline-flex;
    flex-direction: column;
    align-items: center;
}

.statistics-quantity>div>div>p{
	color: #999999;
	text-align: center;
	font-size: 14px;
}

.statistics-quantity>div>div>span{
	font-size: 20px;
	margin-bottom: 4px;
}

.link-image-groups{
    text-align: left;
}

.pic-item {
	text-align: left;
	margin-top: 15px;
}

.pic-item .image-item ,.pic-item img {
	width: 30%;
	height: 70px;
	display: inline-block;
}

.only-one-item img{
	width: 100%;
  height: 150px;
}

.pic-item .image-item ,.pic-item img {
    margin-right: 2%;
}
.pic-item>.no-data-img>img{
	width: 100%;
	height: 100%;
}
.content-detail-title {
	font-size: 15px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	color: rgba(51, 51, 51, 1);
	margin-top: 10px;
	margin-left: -8px;
}

.hiddenCheck-detail {
	background: rgba(225, 225, 225, 0.2);
	padding: 10px;
}

.hiddenCheck-detail .hiddenCheck-detail-item:nth-child(2)>.item-desc {
	/* padding: 8px 0; */
	padding-bottom: 4px;
}

.hiddenCheck-detail .hiddenCheck-detail-item .item-title {
	font-size: 12px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	color: #333333;
	line-height: 14px;
}

.hiddenCheck-detail .hiddenCheck-detail-item .item-desc {
	font-size: 12px;
	font-family: PingFangSC-Regular;
	font-weight: 400;
	color: #999999;
	line-height: 14px;
}

.hiddenCheck-detail .hiddenCheck-detail-item>p{
	text-align: center;
    font-size: 14px;
    color: #444;
}

.hiddenCheck-detail .hiddenCheck-detail-item>p:nth-child(1){
	padding: 4px 0;
}

.link-top-btns{
	position: absolute;
	right:20px;
	top: 10px;
}
.link-page-top img{
	float: left;
    height: 25px;
	width: 25px;
    margin-top: 7px;
}
</style>
<link rel="stylesheet" href="../../../css/framework7.min.css">
</head>

<body style="overflow: hidden">
	<div id="app" class="page page-weekly">
		<div class="link-page-top">
			<div class="link-page-title" id="weeklyTitle"></div>
			<div class="link-top-btns">
				<!-- <i class="iconfont icon-APPicon_fenxiang" style="margin-right:15px;" id="sharePageBtn"></i>
				<span id="voiceBtn">
					<i class="iconfont icon-APPicon_yuyin"></i>
					<img src="../../../img/voice.gif" />
				</span> -->
				<img src="../../../img/share.png" style="margin-right:15px;" id="sharePageBtn" />
				<img src="../../../img/voice.png" id="voiceBtn" />
			</div>
			<div class="link-date" id="weeklyTime"></div>
		</div>
		<div class="page-content" style="overflow-y: auto;">
			<!-- 一周安全态势 -->
			<div class="week-security-situation">
				<div class="situation-chart">
					<div id="situationChart"></div>
				</div>
			</div>

			<!-- 本周危险排行榜前五 -->
			<div class="week-dangerous-leaderboard">
				<div class="content-top-title">
					<p class="title-text">本周最危险单位排名</p>
					<p class="title-desc">按本周“告急”总时长计算</p>
				</div>
				<div class="dangerous-leaderboard-content">
					<ul id="dangerousList">
					</ul>
				</div>
			</div>

			<!-- 高危信号回顾 -->
			<div class="fireHazard-content">
				<div class="content-top-title">
					<p class="title-text">高危信号回顾</p>
				</div>
				<div class="statistics-quantity">
					<div>
						<div>
							<span id="fireHazard-lastWeek"></span>
							<p>上周总数</p>
						</div>
						<div>
							<span id="fireHazard-thisWeek"></span>
							<p>本周总数</p>
						</div>
						<div>
							<span id="fireHazard-precent"></span>
							<p id="fireHazard-text"></p>
						</div>
					</div>
				</div>
				<div class="fireHazard-chart">
					<div id="fireHazardChart"></div>
				</div>
			</div>

			<!-- 重大问题回顾 -->
			<div class="keyIssues-content">
				<div class="content-top-title">
					<p class="title-text">重大问题回顾</p>
				</div>
				<div class="content-detail-title">
					<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png"
						style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
					重大问题周环比</div>
				<div class="statistics-quantity">
					<div>
						<div>
							<span id="keyIssues-lastWeek"></span>
							<p>上周总数</p>
						</div>
						<div>
							<span id="keyIssues-thisWeek"></span>
							<p>本周总数</p>
						</div>
						<div>
							<span id="keyIssues-precent"></span>
							<p id="keyIssues-text">增长</p>
						</div>
					</div>
				</div>
				<div class="keyIssues-chart">
					<div id="keyIssuesChart" class="chart-content" style="width: 100%;"></div>
				</div>
				<div class="keyIssues-leaderboard" id="keyIssuesList_box">
					<div class="content-detail-title">
					<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png" 
				   style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
				   重大问题单位排名</div>
					<ul id="keyIssuesList">
					</ul>
				</div>
			</div>

			<!-- 隐患整改回顾 -->
			<div class="hiddenCheck-content">
				<div class="content-top-title">
					<p class="title-text">隐患整改回顾</p>
					<p class="title-desc">“隐患险于明火，防范胜于救灾！”</p>
				</div>
				<div class="statistics-quantity statistics-two">
					<div>
						<div class="statistics-number">
							<span></span>
							<p>提报隐患</p>
						</div>
						<div class="statistics-Allnumber">
							<span style="color: rgb(250, 124, 90);"></span>
							<p>较大及以上</p>
						</div>
					</div>
				</div>
				<div class="hiddenCheck-chart">
					<div id="hiddenCheckChart"></div>
					<div class="hiddenCheck-chart-info">
						<div>
							<span id="percentageRealNum"></span><span>%</span>
						</div>
						<div>较大及以上</div>
					</div>
				</div>
				<div class="hiddenCheck-detail">
					<div class="hiddenCheck-detail-item">
						<p class="item-tilte">本周隐患提报最多的社会单位</p>
						<p class="item-desc"></p>
					</div>
					<div class="hiddenCheck-detail-item">
						<p class="item-tilte">本周没有提报隐患的社会单位</p>
						<p class="item-desc"></p>
					</div>
				</div>
				<div class="duty-detail-picture duty-detail-picture-hidden">
					<div class="content-detail-title">
						<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png"
							style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
						典型隐患照片</div>
					<div class="pic-item" id="hiddenCheckPic"></div>
				</div>
			</div>

			<!-- 消防通道监测回顾 -->
			<div class="fire-passage">
				<div class="content-top-title">
					<p class="title-text">消防通道监测回顾</p>
				</div>
				<div class="statistics-quantity statistics-two">
					<div>
						<div class="statistics-number">
							<span></span>
							<p>报警单位总数</p>
						</div>
						<div class="statistics-Allnumber">
							<span style="color: rgb(250, 124, 90);"></span>
							<p>消防通道报警总时长</p>
						</div>
					</div>
				</div>
				<div class="keyIssues-leaderboard" id="firePassage_box">
					<div class="content-detail-title">
					<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png" 
				   style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
				   单位消防通道报警时长排名</div>
					<ul id="firePassage">
					</ul>
				</div>
			</div>

			<!-- 电瓶车上楼回顾 -->
			<div class="electromobile-upstaire">
				<div class="content-top-title">
					<p class="title-text">电瓶车上楼回顾</p>
				</div>
				<div class="statistics-quantity statistics-two">
					<div>
						<div class="statistics-number">
							<span></span>
							<p>发现电瓶车上楼电梯总数</p>
						</div>
						<div class="statistics-Allnumber">
							<span style="color: rgb(250, 124, 90);"></span>
							<p>电瓶车上楼总报警次数</p>
						</div>
					</div>
				</div>
				<div class="keyIssues-leaderboard" id="electromobileUpstaire_box">
					<div class="content-detail-title">
					<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png" 
				   style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
				   单位电瓶车报警次数排名</div>
					<ul id="electromobileUpstaire">
					</ul>
				</div>
			</div>
			
			<!-- 煤气罐上楼回顾 -->
			<div class="gas-cylinder-upstaire">
				<div class="content-top-title">
					<p class="title-text">煤气罐上楼回顾</p>
				</div>
				<div class="statistics-quantity statistics-two">
					<div>
						<div class="statistics-number">
							<span></span>
							<p>发现煤气罐上楼电梯总数</p>
						</div>
						<div class="statistics-Allnumber">
							<span style="color: rgb(250, 124, 90);"></span>
							<p>煤气罐上楼总报警次数</p>
						</div>
					</div>
				</div>
				<div class="keyIssues-leaderboard" id="gasCylinderUpstaire_box">
					<div class="content-detail-title">
					<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png" 
				   style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
				   单位煤气罐报警次数排名</div>
					<ul id="gasCylinderUpstaire">
					</ul>
				</div>
			</div>

			<!-- 消控室值守回顾 -->
			<div class="control-room-review">
				<div class="content-top-title">
					<p class="title-text">消控室值守回顾</p>
					<p class="title-desc">“消控室有人值守是消防管理的基石”</p>
				</div>
				<div class="statistics-quantity statistics-two">
					<div>
						<div>
							<span></span>
							<p>不间断值守单位总数</p>
						</div>
						<div>
							<span style="color: rgb(250, 124, 90);"></span>
							<p>发生无人值守情况单位数</p>
						</div>
					</div>
				</div>
				<div class="duty-detail">
					<div class="duty-detail-org" id="dutyDetailList_box">
						<div class="content-detail-title">
							<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png"
								style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
							单位无人值守最长时间排名</div>
						<ul id="dutyDetailList">

						</ul>
					</div>
					<div class="duty-detail-picture" id="dutyPic_box">
						<div class="content-detail-title">
							<img src="/ilink-app-h5-zd/static/img/ilink_1565765076954.png"
								style="vertical-align:middle;width:25px;height:25px;margin-top: -5px;">
							典型无人值守照片</div>
						<div class="pic-item" id="dutyPic"></div>
					</div>
				</div>
			</div>
		</div>
	</div>
</body>
<script src="../../../js/plugins/framework_ilink.js"></script>
<!-- 设置配置文件 -->
<script src="/ilink-fe-config/zhxf-app/config.js?v=202005151646"></script>
<!-- jquery-3.3.1.min.js  -->
<script src="/ilink-app-h5-zd/static/js/rdspFile_1559652823179.js"></script>
<!-- moment.js -->
<script src="/ilink-app-h5-zd/static/js/rdspFile_1559652904949.js"></script>
<!-- echarts.min.js -->
<script src="/ilink-app-h5-zd/static/js/rdspFile_1559652961780.js "></script>
<!-- 进度条插件 -->
<script src="/ilink-app-h5-zd/static/js/rdspFile_1559708991242.js"></script>
<!-- 语音播报插件 -->
<script src="/ilink-app-h5-zd/static/js/ilink_1564575847499.js"></script>

<script type="text/javascript">
	$(function () {

		var app = new Framework7({
			id: 'ilink',
			version:'',
			root: '#app',
			history:false,
			cache: true,//是否打开 Ajax 缓存。最好启用Ajax缓存，特别是你的页面内容不经常更新的时候。（默认值：true）
			cacheDuration: 1000*60*10,//Ajax 缓存时间，在缓存有效期内加载页面不会发起新的ajax请求而是直接使用缓存的结果。（默认是 10 分钟）
			cacheIgnore:[],//不希望被缓存的URL，这是一个字符串数组。（默认为空数组）
			cacheIgnoreGetParameters:false,//缓存是否忽略get参数，如果为 "true"，那么像 "about.html?id=2" 和 "about.html?id=3" 将会和 "about.html" 是一样的缓存。（默认值：false）
			routes: [],
			touch: {
					tapHold: true, //enable tap hold events
			},
			view:{
				stackPages: true
			},
		});

		//如果是给pc端嵌入
		if (!/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent) && !/(Android)/i.test(navigator.userAgent)) {
			$('#sharePageBtn').hide()
		}
		//接口上下文路径
		var contextPath = CONFIGBOX[CONFIGKEY].proxy;
		var isPlay = false;
		var isresume = false;
		$('#voiceBtn').attr("src", "../../../img/voice.png");
		var id = getQueryVariable("reportId");
		$.ajax({
			url: location.origin + "/app/maintainReport/getMaintenanceReportDataForShare?id=" + id,
			type: 'get',
			dataType: 'json',
			success: function (data) {
				if (data) {
					var data = JSON.parse(JSON.parse(xxbubs(data.data)));
					var orgName = data.orgName;
					if (orgName)
						$("#weeklyTitle").html(orgName);
					var sTimes = data.startDate.split('-');
					var startTimeStr = sTimes[1] + "月" + sTimes[2] + "日"
					var eTimes = data.endDate.split('-');
					var endTimeStr = eTimes[1] + "月" + eTimes[2] + "日";
					$("#weeklyTime").empty().html(startTimeStr + "-" + endTimeStr);
					var securitySituation = data.securitySituation;
					if (securitySituation)
						creatSituationChart(securitySituation.urgentHour, securitySituation.dangerHour, securitySituation.securityHour);

					// 本周最危险单位Top5
					var weekDangerTop5 = data.weekDangerTop5;
					$("#dangerousList").empty();
					if (weekDangerTop5.length > 0) {
						for (var i = 0; i < weekDangerTop5.length; i++) {
							$("#dangerousList").append(`
						<li class="dangerousList-item">
							<div class="item-number">
								<div class="item-num-div">`+ (i + 1) + `</div>
							</div>
							<div class="item-desc">
								<div>
									<div class="item-desc-flex">
										<p>`+ weekDangerTop5[i].orgName + `</p>
										<p>`+ weekDangerTop5[i].desc + `</p>
									</div>
									<div id="jqmeter-container_`+ i + `"></div>
								</div>
							</div>
						</li>
					`);

							$('#jqmeter-container_' + i).jQMeter({
								goal: Number(weekDangerTop5[0].time).toFixed(2),
								raised: Number(weekDangerTop5[i].time).toFixed(2),
								orientation: 'vertical',
								width: '100%',
								height: '8px',
								barColor: '#3B82D6',
								bgColor: '#fff',
								displayTotal: false,
							});
						}
					} else {
						$("#dangerousList").append(`<div class="no-data-img">
					<img width="100%" height="100%" src="/ilink-app-h5-zd/static/img/ilink_1566461028161.png"/></div>`);
					}
					// 高危信号回顾
					var highRiskSignal = data.highRiskSignal;
					if (highRiskSignal) {
						var dateArray = {};
						var array1 = [], array2 = [];
						for (var i = 0; i < highRiskSignal.thisWeek.length; i++) {
							array1.push(highRiskSignal.thisWeek[i].value);
						}

						for (var j = 0; j < highRiskSignal.lastWeek.length; j++) {
							array2.push(highRiskSignal.lastWeek[j].value);
						}

						dateArray = {
							'thisWeek': array1,
							'lastWeek': array2
						};
						fireHazardChart(dateArray);
						if(highRiskSignal.lastWeekTime == 0 && highRiskSignal.thisWeekTime == 0){
							$(".fireHazard-chart").hide()
						}
						$("#fireHazard-lastWeek").html(highRiskSignal.lastWeekTime);
						$("#fireHazard-thisWeek").html(highRiskSignal.thisWeekTime);
						var result = parseInt(highRiskSignal.lastWeekTime) - parseInt(highRiskSignal.thisWeekTime);
						if (highRiskSignal.lastWeekTime == "0") {
							$("#fireHazard-text").html("增长");
							$("#fireHazard-precent").css("color", "#FA7C5A");
							$("#fireHazard-precent").html(highRiskSignal.percent);
						} else if (result >= 0) {  // 降低
							$("#fireHazard-text").html("降低");
							$("#fireHazard-precent").css("color", "#75CD7E");
							$("#fireHazard-precent").html(highRiskSignal.percent + "%");
						} else {  // 增加
							$("#fireHazard-text").html("增长");
							$("#fireHazard-precent").css("color", "#FA7C5A");
							$("#fireHazard-precent").html(highRiskSignal.percent + "%");
						}

					}
					// 重大问题
					var majorIssuesProportion = data.majorIssuesProportion;
					if (majorIssuesProportion) {
						if(majorIssuesProportion.lastWeekTime == 0 && majorIssuesProportion.thisWeekTime == 0){
							$(".keyIssues-chart").hide()
						}
						var dateArray1 = {};
						var array1 = [], array2 = [];
						for (var i = 0; i < majorIssuesProportion.thisWeek.length; i++) {
							array1.push(majorIssuesProportion.thisWeek[i].number);
						}

						for (var j = 0; j < majorIssuesProportion.lastWeek.length; j++) {
							array2.push(majorIssuesProportion.lastWeek[j].number);
						}

						dateArray1 = {
							'thisWeek': array1,
							'lastWeek': array2
						};
						keyIssuesChart(dateArray1);
						$("#keyIssues-lastWeek").html(majorIssuesProportion.lastWeekTime);
						$("#keyIssues-thisWeek").html(majorIssuesProportion.thisWeekTime);
						var majorIssues_result = parseInt(majorIssuesProportion.thisWeekTime) - parseInt(majorIssuesProportion.lastWeekTime);
						if (majorIssuesProportion.lastWeekTime == '0') {
							$("#keyIssues-text").html("增长");
							$("#keyIssues-precent").css("color", "#FA7C5A");
							$("#keyIssues-precent").html(majorIssuesProportion.percent);
						} else if (majorIssues_result > 0) { // 增长了
							$("#keyIssues-text").html("增长");
							$("#keyIssues-precent").css("color", "#FA7C5A");
							$("#keyIssues-precent").html(majorIssuesProportion.percent + "%");
						} else {
							$("#keyIssues-text").html("降低");
							$("#keyIssues-precent").css("color", "#75CD7E");
							$("#keyIssues-precent").html(majorIssuesProportion.percent + "%");
						}
					}
					// 重大问题-前五排行榜
					var majorIssuesOrgTop5 = data.majorIssuesOrgTop5;
					$("#keyIssuesList").empty();
					if (majorIssuesOrgTop5.length > 0) {
						for (var n = 0; n < majorIssuesOrgTop5.length; n++) {
							$("#keyIssuesList").append(`
									<li>
									<div class="item-number">
										<div class="item-num-div">`+ (n + 1) + `</div>
									</div>
									<div class="item-content">
										<div>`+ majorIssuesOrgTop5[n].orgName + `</div> 
										<div style="float: right;">`+ majorIssuesOrgTop5[n].number + `次</div>
									</div>
									</li>		
						`);
						}
					} else {
						$("#keyIssuesList_box").hide()
						// $("#keyIssuesList").append(`
						// <div class="no-data-img">
						// <img width="100%" height="100%"
						// 	src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
						// </div>
						// `);
					}

					if(data.aiResult){
						for(let i in data.aiResult){
							if(data.aiResult[i].code === "electricBicycleUse"){
								var electricBicycleUse = data.aiResult[i] /* 电瓶车上楼 */
							}else if(data.aiResult[i].code === "gasCanistersUse"){
								var gasCanistersUse = data.aiResult[i] /* 煤气罐上楼 */
							}else if(data.aiResult[i].code === "fireEscapeUse"){
								var fireEscapeUse = data.aiResult[i] /* 消防通道监测回顾 */
							}else if(data.aiResult[i].code === "controlRoomUse"){
								var controlRoomUse = data.aiResult[i] /* 无人值守分析 */
							}
						}
					}
					
					// 消防通道监测回顾
					if(fireEscapeUse){
						// 报警单位总数
						$(".fire-passage .statistics-number span").html(fireEscapeUse.totalAlarmOrg)
						// 消防通道报警总时长
						$(".fire-passage .statistics-Allnumber span").html(fireEscapeUse.totalContinueTimeStr)
						// 单位消防通道报警时长排名
						$("#firePassage").empty();
						if(fireEscapeUse.dataList.length>0){
							for(let i=0;i<fireEscapeUse.dataList.length;i++){
								$("#firePassage").append(`
									<li>
									<div class="item-number">
									<div class="item-num-div">`+ (i + 1) + `</div>
									</div>
									<div class="item-content">
									<div>`+ fireEscapeUse.dataList[i].orgName + `</div>
									<div style="float: right;">`+ fireEscapeUse.dataList[i].continueTimeStr + `</div>
									</div>
									</li>
								`);
							}
						}else{
							$("#firePassage_box").hide()
							// $("#firePassage").append(`
							// 	<div class="no-data-img">
							// 		<img width="100%" height="100%"
							// 			src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
							// 	</div>
							// `);
						}
					}else{
						$(".fire-passage").hide()
					}

					// 电瓶车上楼
					if(electricBicycleUse){
						// 发现电瓶车上楼电梯总数
						$(".electromobile-upstaire .statistics-number span").html(electricBicycleUse.totalAlarmFcf)
						// 电瓶车上楼总报警次数
						$(".electromobile-upstaire .statistics-Allnumber span").html(electricBicycleUse.totalAlarmTimes)
						// 单位电瓶车报警次数排名
						$("#electromobileUpstaire").empty();
						if(electricBicycleUse.dataList.length>0){
							for(let i=0;i< electricBicycleUse.dataList.length;i++){
								$("#electromobileUpstaire").append(`
									<li>
									<div class="item-number">
									<div class="item-num-div">`+ (i + 1) + `</div>
									</div>
									<div class="item-content">
									<div>`+ electricBicycleUse.dataList[i].orgName + `</div>
									<div style="float: right;">`+ electricBicycleUse.dataList[i].times + `次</div>
									</div>
									</li>
								`);
							}
						}else{
							$("#electromobileUpstaire_box").hide()
							// $("#electromobileUpstaire").append(`
							// 	<div class="no-data-img">
							// 		<img width="100%" height="100%"
							// 			src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
							// 	</div>
							// `);
						}
						
					}else{
						$(".electromobile-upstaire").hide()
					}

					// 煤气罐上楼
					if(gasCanistersUse){
						// 发现煤气罐上楼电梯总数
						$(".gas-cylinder-upstaire .statistics-number span").html(gasCanistersUse.totalAlarmFcf)
						// 煤气罐上楼总报警次数
						$(".gas-cylinder-upstaire .statistics-Allnumber span").html(gasCanistersUse.totalAlarmTimes)
						// 单位煤气罐报警次数排名
						$("#gasCylinderUpstaire").empty();
						if(gasCanistersUse.dataList.length>0){
							for(let i=0;i<gasCanistersUse.dataList.length;i++){
								$("#gasCylinderUpstaire").append(`
									<li>
									<div class="item-number">
									<div class="item-num-div">`+ (i + 1) + `</div>
									</div>
									<div class="item-content">
									<div>`+ gasCanistersUse.dataList[i].orgName + `</div>
									<div style="float: right;">`+ gasCanistersUse.dataList[i].times + `次</div>
									</div>
									</li>
								`);
							}
						}else{
							$("#gasCylinderUpstaire_box").hide()
							// $("#gasCylinderUpstaire").append(`
							// 	<div class="no-data-img">
							// 		<img width="100%" height="100%"
							// 			src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
							// 	</div>
							// `);
						}
					}else{
						$(".gas-cylinder-upstaire").hide()
					}

					// 隐患整改回顾
					var hiddenDangerReform = data.hiddenDangerReform;
					if (hiddenDangerReform) {
						var numEl = $(".hiddenCheck-content .statistics-two").find("span");
						numEl.eq(0).html(hiddenDangerReform.total);
						numEl.eq(1).html(hiddenDangerReform.maxLevel);
						var total = hiddenDangerReform.total;
						let percentageNum = 0;
						if (total != 0) {
							percentageNum = (((hiddenDangerReform.maxLevel) / total).toFixed(2) * 100);
							percentageNum = Math.round(percentageNum);
						}
						$("#percentageRealNum").html(percentageNum);
						hiddenCheckChart(hiddenDangerReform.maxLevel);
						var element = $(".hiddenCheck-detail-item");
						var maxOrgName = hiddenDangerReform.maxOrgName;
						var notHiddenDangerOrgName = hiddenDangerReform.notHiddenDangerOrgName;
						if (maxOrgName != "" && notHiddenDangerOrgName != "") {
							element.find('p').eq(1).html(hiddenDangerReform.maxOrgName + '，总计提报' + hiddenDangerReform.maxNumber + '次');
							var noOrgNameList = notHiddenDangerOrgName.split(',');
							// var length = (hiddenDangerReform.maxNumber) <= 3?(hiddenDangerReform.maxNumber):3;
							var length = hiddenDangerReform.notHiddenDangerOrgNumber;
							var str = '';
							for (var m = 0; m < length; m++) {
								str += noOrgNameList[m] + '、';
							}
							if (str != '') {
								str = str.substring(0, str.length - 1);
							}
							// str = str+"等";
							element.find('p').eq(3).html("共有" + hiddenDangerReform.notHiddenDangerOrgNumber + "家，包括" + str);
						}
						else if (maxOrgName == "" && notHiddenDangerOrgName != "") {
							$(".hiddenCheck-detail-item").eq(0).remove();
							var noOrgNameList = notHiddenDangerOrgName.split(',');
							// var length = (hiddenDangerReform.maxNumber) <= 3?(hiddenDangerReform.maxNumber):3;
							var length = hiddenDangerReform.notHiddenDangerOrgNumber;
							var str = '';
							for (var m = 0; m < length; m++) {
								str += '【' + noOrgNameList[m] + '】、';
							}
							// str = str+"等";
							element.find('p').eq(3).html("共有【" + hiddenDangerReform.notHiddenDangerOrgNumber + "家】，包括" + str);
						} else if (maxOrgName != "" && notHiddenDangerOrgName == "") {
							$(".hiddenCheck-detail-item").eq(1).remove();
							element.find('p').eq(1).html('【' + hiddenDangerReform.maxOrgName + '】，总计提报【' + hiddenDangerReform.maxNumber + '次】');
						} else {
							$(".hiddenCheck-detail").empty();
						}
					}
					var hiddenDangerPics = hiddenDangerReform.hiddenDangerPics;
					$("#hiddenCheckPic").empty();
					if (hiddenDangerPics) {
						var picList_h = hiddenDangerPics.split(',');
						for (var n = 0; n < picList_h.length; n++) {
							$("#hiddenCheckPic").append(`<img src="` + picList_h[n] + `" data-index="${n}" />`);
						}
						if(picList_h.length==1){
							$("#hiddenCheckPic").addClass('only-one-item')
						}else{
							$("#hiddenCheckPic").removeClass('only-one-item')
						}
						
						$("#hiddenCheckPic img").click((e)=>{
							var photoBrowser=app.photoBrowser.create({
								photos: picList_h,
								type: 'standalone',
								routableModals:false,
								backLinkText: 'Back',
								theme: 'dark',
								expositionHideCaptions:true,
								swipeToClose:true,
								toolbar:false,
								navbarOfText:'/'
							});
							photoBrowser.open($(e.currentTarget).data('index'))
						})
					} else {
						$(".duty-detail-picture.duty-detail-picture-hidden").hide()
						// 	$("#hiddenCheckPic").append(`
						// <div class="no-data-img">
						// <img width="100%" height="100%"
						// 	src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
						// </div>
						// `);
					}
				// 消控室值守回顾
				var controlRoom = data.controlRoom;
				if(!controlRoom && !controlRoomUse){
					$(".control-room-review").hide()
				}else if(controlRoom && !controlRoomUse){
					if(controlRoom){
						$(".control-room-review .statistics-two").find("span").eq(0).html(controlRoom.orgExistPersonTotal);
						$(".control-room-review .statistics-two").find("span").eq(1).html(controlRoom.orgNotPersonTotal);
					}
					var personnelDutyTop = controlRoom.personnelDutyTop;
					$("#dutyDetailList").empty();
					if(personnelDutyTop != null) {
						for(var i=0;i<personnelDutyTop.length;i++) {
							$("#dutyDetailList").append(`
										<li>
										<div class="item-number">
										<div class="item-num-div">`+ (i + 1) + `</div>
										</div>
										<div class="item-content">
										<div>`+ personnelDutyTop[i].orgName + `</div>
										<div style="float: right;">`+ personnelDutyTop[i].desc + `</div>
										</div>
										</li>
							`);
						}
					} else {
						$("#dutyDetailList_box").hide()
						// $("#dutyDetailList").append(`
						// 	<div class="no-data-img">
						// 	<img width="100%" height="100%"
						// 		src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
						// 	</div>
						// `);
					}
					var notPersonnelDutyPics = controlRoom.notPersonnelDutyPics;
					$("#dutyPic").empty();
					if (notPersonnelDutyPics) {
						var picList_d = notPersonnelDutyPics.split(',');
						for (var n = 0; n < picList_d.length; n++) {
							$("#dutyPic").append(`<img src="` + picList_d[n] + `" data-index="${n}" />`);
						}
						if(picList_d.length==1){
							$("#dutyPic").addClass('only-one-item')
						}else{
							$("#dutyPic").removeClass('only-one-item')
						}
						
						$("#dutyPic img").click((e)=>{
							var photoBrowser=app.photoBrowser.create({
								photos: picList_d,
								type: 'standalone',
								routableModals:false,
								backLinkText: 'Back',
								theme: 'dark',
								expositionHideCaptions:true,
								swipeToClose:true,
								toolbar:false,
								navbarOfText:'/'
							});
							photoBrowser.open($(e.currentTarget).data('index'))
						})
					} else {
						$("#dutyPic_box").hide()
						// $("#dutyPic").append(`
						// <div class="no-data-img">
						// <img width="100%" height="100%"
						// 	src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
						// </div>
						// `);
					}	
				}else if(!controlRoom && controlRoomUse){
					if(controlRoomUse){
						$(".control-room-review .statistics-two").find("span").eq(0).html(controlRoomUse.totalNormalOrg);
						$(".control-room-review .statistics-two").find("span").eq(1).html(controlRoomUse.totalAlarmOrg);
					}
					var notPersonnelDutyPics = controlRoomUse.dataList;
					$("#dutyDetailList").empty();
					if(notPersonnelDutyPics.length>0) {
						for(var i=0;i<notPersonnelDutyPics.length;i++) {
							$("#dutyDetailList").append(`
										<li>
										<div class="item-number">
										<div class="item-num-div">`+ (i+1) + `</div>
										</div>
										<div class="item-content">
										<div>`+ notPersonnelDutyPics[i].orgName + `</div>
										<div style="float: right;">`+ notPersonnelDutyPics[i].continueTimeStr + `</div>
										</div>
										</li>
							`);
						}
					} else {
						$("#dutyDetailList_box").hide()
						// $("#dutyDetailList").append(`
						// 	<div class="no-data-img">
						// 	<img width="100%" height="100%"
						// 		src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
						// 	</div>
						// `);
					}
					$("#dutyPic").empty();
					var notPersonnelDutyPic = ""
					if (notPersonnelDutyPics.length>0) {
						for(let j in notPersonnelDutyPics){
							if(notPersonnelDutyPics.lenth>1){
								notPersonnelDutyPic += notPersonnelDutyPics[j].picUrl + ","
							}else{
								notPersonnelDutyPic = notPersonnelDutyPics[j].picUrl
							}
						}
						var picList_d = notPersonnelDutyPic.split(',')
						for (var n = 0; n < picList_d.length; n++) {
							$("#dutyPic").append(`<img src="` + picList_d[n] + `" data-index="${n}" />`);
						}
						if(picList_d.length==1){
							$("#dutyPic").addClass('only-one-item')
						}else{
							$("#dutyPic").removeClass('only-one-item')
						}
						$("#dutyPic img").click((e)=>{
							var photoBrowser=app.photoBrowser.create({
								photos: picList_d,
								type: 'standalone',
								routableModals:false,
								backLinkText: 'Back',
								theme: 'dark',
								expositionHideCaptions:true,
								swipeToClose:true,
								toolbar:false,
								navbarOfText:'/'
							});
							photoBrowser.open($(e.currentTarget).data('index'))
						})
					} else {
						$("#dutyPic_box").hide()
						// $("#dutyPic").append(`
						// 	<div class="no-data-img">
						// 		<img width="100%" height="100%"
						// 			src="/ilink-app-h5-zd/static/img/ilink_1564368528154.png">
						// 	</div>
						// `);
					}	
				}
				

				// 分享
					$('#sharePageBtn').click(function(){
						shareReport(document.location.href,orgName,startTimeStr+"-"+endTimeStr+"消防报表");
					});
					$('#voiceBtn').click(function () {
						//还没播放
						if (!isPlay) {
							if (data.reportDesc) {
								Voice.play(data.reportDesc, function () {
									isPlay = true;
									$('#voiceBtn').attr("src", "../../../img/voice.gif");
								}, function () {
									isresume = true;
									$('#voiceBtn').attr("src", "../../../img/voice.png");
									Voice.pause();
								});
							} else {
								try {
									top.window.app.methods.showToastCenter("未找到语音文件");
								} catch (error) {
								}
							}
						}
						//已经播放-暂停
						else if (!isresume) {
							isresume = true;
							$('#voiceBtn').attr("src", "../../../img/voice.png");
							Voice.pause();
						}
						//暂停中-继续播放
						else {
							isresume = false;
							$('#voiceBtn').attr("src", "../../../img/voice.gif");
							Voice.resume();
						}
					});

				} else {
					//$("").append();
				}
			}
		})
	});

	// 一周安全趋势图
	function creatSituationChart(value1, value2, value3) {
		var dom = document.getElementById('situationChart');
		var situationChart = echarts.init(dom);
		var basicData = [
			{ 'name': '告急时长', 'value': value1 },
			{ 'name': '危险时长', 'value': value2 },
			{ 'name': '安全时长', 'value': value3 }
		];
		var options = {
			title: {
				text: '一周安全态势'
			},
			color: ['#FA7B59', '#FFC95D', '#75CD7E',],
			legend: {
				orient: 'vertical',
				x: '60%',
				y: 'center',
				data: [{
					name: '告急时长',
					icon: 'image:///ilink-app-h5-zd/static/img/rdspFile_1559699271314.png',
				}, {
					name: '危险时长',
					icon: 'image:///ilink-app-h5-zd/static/img/rdspFile_1559699285778.png',
				}, {
					name: '安全时长',
					icon: 'image:///ilink-app-h5-zd/static/img/rdspFile_1559699251651.png ',
				}
				],
				formatter: function (name) {
					var target;
					for (var i = 0, l = basicData.length; i < l; i++) {
						if (basicData[i].name == name) {
							target = basicData[i].value;
						}
					}
					var arr = ['{a|' + name + '}', '{b|' + target + '小时}',];
					return arr.join('\n');
				},
				textStyle: {
					rich: {
						a: {
							fontSize: 12,
							verticalAlign: 'bottom',
							align: 'left',
							color: '#999999',
							fontWeight: 600,
							padding: [0, 0, 20, 0]
						},
						b: {
							fontSize: 14,
							align: 'left',
							color: '#333333',
							lineHeight: 25
						}
					}
				}
			},
			series: [{
				type: 'pie',
				radius: ['40%', '45%'],
				center: ['35%', '50%'],
				// label : {
				// 	normal : {
				// 		show : false,
				// 		position : 'left'
				// 	},
				// 	emphasis : {
				// 		show : true,
				// 		textStyle : {
				// 			fontSize : '12',
				// 			fontWeight : 'bold'
				// 		}
				// 	}
				// },
				labelLine: {
					normal: {
						length: 10,
						lineStyle: {
							color: '#E1E1E1'
						}
					}

				},
				label: {
					normal: {
						formatter: '{d}%',
						borderRadius: 4,
						padding: [0, -20],
					}
				},
				data: [{
					value: value1,
					name: '告急时长',
				}, {
					value: value2,
					name: '危险时长',
				}, {
					value: value3,
					name: '安全时长',
				}]
			}]
		};
		situationChart.setOption(options, true);
		window.onresize = function () {
			situationChart.resize();
		}
	}

	// 高危信号折线图
	function fireHazardChart(data) {
		var dom = document.getElementById("fireHazardChart");
		var fireHazardChart = echarts.init(dom);
		var option = {
			tooltip: {
				backgroundColor: '#fff',
				borderColor: '#F3F3F3C7', // 提示边框颜色
				borderRadius: 6, // 提示边框圆角，单位px，默认为4
				borderWidth: 1,
				position: function (p) { //其中p为当前鼠标的位置
					return [p[0] - 28, p[1] - 70];
				},
				padding: 10,
				trigger: 'axis',
				formatter: function (params) {
					res = "<span style='color:#999999;font-size:10px;float:left;'>"
						+ params[1].seriesName
						+ ": <label>"
						+ params[1].value
						+ "</label></span><br/>"
						+ "<span style='color:#999999;font-size:10px;float:left;'>"
						+ params[0].seriesName
						+ ": <label>"
						+ params[0].value + "</label></span><br/>"
					return res;
				},
				axisPointer: {
					type: 'shadow',
					axis: 'x',
					z: 2,
				},
				extraCssText: 'box-shadow: 0px 0px 15px 0px rgba(129,129,129,0.2);height:40px;'
			},
			xAxis: [{
				type: 'category',
				axisTick: {
					show: false
				},
				scale: true,
				splitLine: {
					show: false,
				},
				axisLine: {
					show: false,
				},
				data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日']
			}],
			yAxis: [{
				type: 'value',
				splitNumber: 2,
				scale: true,
				show: false,
				splitLine: {
					show: false
				}
			}],
			series: [{
				name: '上周',
				type: 'line',
				areaStyle: {
					normal: {
						color: 'rgba(208,215,255,0.6)'
					}
				},
				itemStyle: {
					normal: {
						lineStyle: {
							color: '#D0D7FF'
						}
					}
				},
				symbol: 'none',
				smooth: true,
				data: data.lastWeek
			}, {
				name: '本周',
				type: 'line',
				label: {
					normal: {}
				},
				areaStyle: {
					normal: {
						color: 'rgba(255,255,255,0.7)'
					}
				},
				itemStyle: {
					normal: {
						lineStyle: {
							color: '#3B82D6'
						}
					}
				},
				symbol: 'none',
				smooth: true,
				data: data.thisWeek
			}]
		};
		fireHazardChart.setOption(option, true);
	}

	// 重大问题柱状图
	function keyIssuesChart(data) {
		var dom = document.getElementById("keyIssuesChart");
		var keyIssuesChart = echarts.init(dom);
		var map4_data1 = [120, 332, 51, 34, 90];
		var map4_data2 = [220, 482, 191, 234, 290];
		var options = {
			color: ['#E1E1E1', '#4F8DD4'],
			tooltip: {
				backgroundColor: '#fff',
				borderColor: '#F3F3F3C7', // 提示边框颜色
				borderRadius: 6, // 提示边框圆角，单位px，默认为4
				borderWidth: 1,
				position: function (p) { //其中p为当前鼠标的位置
					return [p[0] - 80, p[1] - 70];
				},
				trigger: 'axis',
				padding: 10,
				formatter: function (params) {
					res = "<span style='color:#999999;font-size:10px;float:left;'>"
						+ params[1].seriesName
						+ ": <label>"
						+ params[1].value
						+ "</label></span><br/>"
						+ "<span style='color:#999999;font-size:10px;float:left;'>"
						+ params[0].seriesName
						+ ": <label>"
						+ params[0].value + "</label></span><br/>"
					return res;
				},
				textStyle: {
					align: 'center'
				},
				extraCssText: 'box-shadow: 0px 0px 15px 0px rgba(129,129,129,0.2);height:40px;'
			},
			calculable: true,

			xAxis: [{
				type: 'category',
				boundaryGap: true,
				axisTick: {
					show: false
				},
				scale: true,
				splitLine: {
					show: false,
				},
				axisLine: {
					show: false,
				},
				axisLabel: {
					interval: 0,
					textStyle: {
						color: '#999999'
					},
					formatter: function (params) {
						var newParamsName = "";
						var clientWidth = document.body.clientWidth; // 可见区域宽度
						var paramsNameNumber = params.length;

						if (clientWidth >= 400) {
							if (paramsNameNumber >= 4) {
								newParamsName = addWrap(0, 4, paramsNameNumber,
									params);
							} else {
								newParamsName = params;
							}
						} else if (clientWidth <= 350) {
							if (paramsNameNumber >= 2) {
								newParamsName = addWrap(0, 2, paramsNameNumber,
									params);

							} else {
								newParamsName = params;
							}
						} else {
							if (paramsNameNumber >= 3) {
								newParamsName = addWrap(0, 3, paramsNameNumber,
									params);
							} else {
								newParamsName = params;
							}
						}
						return newParamsName;
					}
				},
				data: ['消控室无人值守', '消防通道堵塞', '重点消防设施', '消防系统完好性缺失', '日常巡检持续未完成']
			}],
			yAxis: [{
				type: 'value',
				splitNumber: 2,
				scale: true,
				show: false,
				splitLine: {
					show: false
				}
			}],
			series: [{
				name: '上周',
				type: 'bar',
				barGap: 0,
				data: data.lastWeek,

			}, {
				name: '本周',
				type: 'bar',
				data: data.thisWeek,

			}]
		};

		keyIssuesChart.setOption(options, true);
	}

	//

	function hiddenCheckChart(value) {
		var dom = document.getElementById('hiddenCheckChart');
		var hiddenCheckChart = echarts.init(dom);
		var option = {
			color: ['#FA7B59', '#F1F1F1'],
			series: [{
				name: '',
				type: 'pie',
				radius: ['50%', '60%'],
				center: ['50%', '50%'],
				avoidLabelOverlap: false,
				label: {
					normal: {
						show: false,
						position: 'center'
					},
					emphasis: {
						show: true,
						textStyle: {
							fontSize: '30',
							fontWeight: 'bold'
						}
					}
				},
				labelLine: {
					normal: {
						show: false
					}
				},
				data: [{
					value: value,
					name: ''
				}, {
					value: 100 - value,
					name: ''
				},]
			}]
		};
		hiddenCheckChart.setOption(option, true);
	}

	// 增加换行符
	function addWrap(startNum, endNum, total, str) {
		var newStr = "";
		if (total <= endNum) {
			newStr = str;
		} else {
			newStr = str.substring(startNum, endNum);
			var remainNum = total - endNum;
			var newStartNum = endNum;
			var newEndNum = endNum + endNum;
			if (remainNum <= endNum) {
				newStr = newStr + "\n" + str.substring(newStartNum, total);
			} else {
				newStr = newStr + "\n" + str.substring(endNum, newEndNum);
				var stri = addWrap(newStartNum, newEndNum, total, str
					.substring(endNum, total));
				newStr = newStr + "\n" + stri;
			}
		}

		return newStr;
	}

	//只能分享一次
	//后面优化成h5
	function shareReport(url, shareTitle, shareContent) {
		parent.native.shareReport(decodeURIComponent(url), shareTitle, shareContent);
	}

	function xxbubs(str) {
		str = str.replace("f6ae12c1671b4ce48c3f90e9dd9d7608", "");
		return decodeURIComponent(atob(str).split('').map(function (c) {
			return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
		}).join(''));
	}

	function getQueryVariable(variable) {
		var query = window.location.search.substring(1);
		var vars = query.split("&");
		for (var i = 0; i < vars.length; i++) {
			var pair = vars[i].split("=");
			if (pair[0] == variable) { return pair[1]; }
		}
		return (false);
	}
</script>

</html>